<div id="preject">
    {switch $type}
     {case 1}

    <div class="title"><strong>报名项目</strong></div>
    {foreach $preject as $v}
    <dl><dd><a  href="{:url('content')}?id={$v.id}&type=1">{$v.title|mb_substr=0,20,'utf-8'}</a></dd></dl>
    {/foreach}
    {/case}
    {case 2}

    <div class="title"><strong>公告</strong></div>
    {foreach $notice as $v}
    <dl> <dd><a  href="{:url('content')}?id={$v.id}&type=2">{$v.title|mb_substr=0,20,'utf-8'}</a></dd>
    </dl>
    {/foreach}
    {/case}
    {case 3}

    <div class="title"><strong>常见问题</strong></div>
    {foreach $question as $v}
    <dl> <dd><a  href="{:url('content')}?id={$v.id}&type=3">{$v.title|mb_substr=0,20,'utf-8'}</a></dd>
    </dl>
    {/foreach}
    {/case}
    {/switch}
</div>